home *** CD-ROM | disk | FTP | other *** search
/ Magnum One / Magnum One (Mid-American Digital) (Disc Manufacturing).iso / d20 / pxsrc21a.arc / POLYXIBM.TEK < prev    next >
Text File  |  1991-05-12  |  4KB  |  124 lines

  1.  
  2.  
  3.  
  4.  
  5.                           Technical notes for PolyXarc
  6.  
  7.         I originally compiled PolyXarc with Microsoft C 5.1 because  it's 
  8.         the compiler I normally use. Then I ran some tests with  PolyXarc 
  9.         and  RMAP.  RMAP is a program that reports memory  usage  in  the 
  10.         system,  including the remaining memory. RMAP was reporting  that 
  11.         PolyXarc used up 96688 bytes of memory. But when I converted over 
  12.         to Turbo C 2.0, RMAP reported only 32112 bytes used.
  13.  
  14.         I  did  more tests, trying out different memory  models.  Compact 
  15.         model  was the best, having a 64k code limitation but  allocating 
  16.         data  from the system, rather than from the stack as small  model 
  17.         does. MSC's best model (small) required exactly as much memory as 
  18.         TC's  worst  model (medium). Just for comparison,  here  are  the 
  19.         figures I got:
  20.  
  21.                      Turbo C                   Microsoft C
  22.         -----------------------------------------------------------------
  23.         Small         83744                       84512
  24.         Medium        84512                       85280
  25.         Compact       32112                       96688
  26.         Large         33136                       97472
  27.  
  28.         Since  memory  requirements in this application are  critical,  I 
  29.         elected  to go with Turbo C without hesitation. However,  I  have 
  30.         left a copy of the Microsoft C make file in case somebody has MSC 
  31.         and not TC, and the source files have conditional compilations to 
  32.         make  up  the  difference. I also have the MSC  file  set  up  to 
  33.         compile  in  small model, and the TC file to compile  in  compact 
  34.         model.
  35.  
  36.         Because  of  the  configurable nature of  PolyXarc,  testing  the 
  37.         memory  size is a breeze. You can easily set up a fake  signature 
  38.         to  call a program like CHKDSK, and then create a test file  with 
  39.         that signature to trigger the test. That's what I did, using RMAP 
  40.         instead of CHKDSK because it's faster.
  41.  
  42.         Contents of TEST.TST:
  43.         TEST
  44.  
  45.         Signature line in POLYXARC.CFG:
  46.            SIGNATURE 1   0   TEST    -o         RMAP
  47.  
  48.         Naturally,  PolyXarc's memory requirements have changed a  little 
  49.         since  I  made  those initial tests, but I expect  that  TC  will 
  50.         continue to blow MSC out of the water for memory size.
  51.  
  52.         To make PolyXarc with Turbo C without debug records:
  53.  
  54.              make -DDEBUG=/x -fmakpolyx.tc
  55.  
  56.         with debug records:
  57.  
  58.              make -DDEBUG=/s/l/m/v -fmakpolyx.tc
  59.  
  60.  
  61.  
  62.                                    1
  63.  
  64.  
  65.  
  66.         With Microsoft C without Codeview records:
  67.  
  68.              make makpolyx.msc
  69.  
  70.         with Codeview records:
  71.  
  72.              make optlevel=/Od debug=/Zi linkopt=/CO makpolyx.msc
  73.  
  74.         That last line also disables optimization. If you use Codeview to 
  75.         debug  PolyXarc and then want to distribute it, I  recommend  you 
  76.         delete the .OBJ files to force a complete recompilation.
  77.  
  78.         Notice that while both sets of files use the MAKE program, the TC 
  79.         make  file assumes you are using Borland's MAKE program, and  the 
  80.         MSC  make  file assumes you are using Microsoft's  MAKE  program. 
  81.         There are critical differences.
  82.  
  83.                                       - Jeffrey J. Nonken
  84.  
  85.  
  86.  
  87.  
  88.  
  89.  
  90.  
  91.  
  92.  
  93.  
  94.  
  95.  
  96.  
  97.  
  98.  
  99.  
  100.  
  101.  
  102.  
  103.  
  104.  
  105.  
  106.  
  107.  
  108.  
  109.  
  110.  
  111.  
  112.  
  113.  
  114.  
  115.  
  116.  
  117.  
  118.  
  119.  
  120.  
  121.  
  122.  
  123.                                    2
  124.